import Link from 'next/link';
import { WeatherWidget } from '@/components/weather-widget';
import { Button } from '@/components/ui/button';
import { PenSquare } from 'lucide-react';

export function AppHeader() {
  return (
    <header className="sticky top-0 z-40 w-full bg-background/80 backdrop-blur-sm border-b">
      <div className="container mx-auto flex h-20 items-center justify-between px-4 sm:px-6 lg:px-8">
        <Link href="/" className="flex items-center space-x-2">
          <span className="font-headline text-3xl font-bold text-primary-foreground tracking-wider">
            樱の语
          </span>
        </Link>
        <div className="flex items-center space-x-4">
          <Button variant="ghost" asChild>
            <Link href="/create">
              <PenSquare className="mr-2" />
              创建文章
            </Link>
          </Button>
          <WeatherWidget />
        </div>
      </div>
    </header>
  );
}
